<template>
  <a-carousel autoplay>
    <template v-for="(item, index) in formData" v-if="formData.length>0">
      <img :src="getAvatarView(item)" :key="index" style="height: 240px;width:100%"/>
    </template>
    <template v-else>
      <img src="@assets/nodata.png" :key="index" style="height: 240px;width:100%"/>
    </template>
  </a-carousel>
</template>

<script>
  import { getFileAccessHttpUrl } from '@/api/manage'

  export default {
    name: 'EoaCmsBanner',
    props: ['formData'],
    methods: {
      getAvatarView(url){
        return getFileAccessHttpUrl(url)
      },
    }
  }
</script>

<style scoped>

</style>